Fundamental Data Types – Other
VectorScript also supports the following data types: BOOLEAN, HANDLE, and VECTOR.
BOOLEAN
BOOLEAN data values may hold one of two values, the truth values (and reserved words) TRUE or FALSE. Values of the BOOLEAN type are more closely similar to Java or JavaScript boolean values in that they are a distinct type; unlike C or C++, they do not use numeric values to simulate TRUE or FALSE.
Boolean values are generally the result of comparison operations that occur within a script, and they are most often used for decision making during script execution.
HANDLE
HANDLE values in VectorScript are used to store a reference to other VectorWorks data in memory. Values of type HANDLE are most often used to reference data related to objects, layers, classes, or other VectorWorks internal structures. VectorScript makes extensive use of HANDLE values throughout the VectorScript API as an easy means of retrieving or setting this data directly from a script.
Aside from a reference to data located in memory, HANDLE values can also be set to the value NIL. As explained in The NIL Literal, the value NIL indicates no reference exists or was found.
Since HANDLE values are references to dynamic memory locations, they should not be stored or otherwise treated as if they were permanent reference to a given item within a document. Storing and reusing HANDLE values can cause errors or other unpredictable behavior within your scripts.
VECTOR
VectorScript provides the specialized VECTOR data type to support vector operations within VectorScript. Vectors are used to represent quantities which have an associated displacement, characterized by a direction and a distance (or magnitude). A VectorScript VECTOR consists of three component REAL values which can also be treated as a single unit value.
When used in conjunction with the vector API of the VectorScript language, VECTOR values can be highly useful in performing complex geometric computations in scripts. Details on this API may be found in the VectorScript Function Reference.
POINT
The POINT data type is used to store the coordinates of a 2D point. It is a compound data type consisting of two component REAL values: x and y. The value is assumed to be in the units of the current document, and relative to the document origin.
POINT3D
The POINT3D data type is used to store the coordinates of a point in 3D space. It is a compound data type consisting of three component REAL values: x, y, and z. The value is assumed to be in the units of the current document, and relative to document origin.
RGBCOLOR
The RGBCOLOR data type can store a color as three components: red, green, and blue. Each component is a LONGINT value.

Variables, Constants, and Data Types : VectorScript Data Types : Fundamental Data Types – Other

Nemetschek NA
Phone: 410.290.5114
Fax: 410.290.8050